/*
 * @description: 跳转到登录页
 * @Author: wxy
 * @Date: 2019-01-18 13:26:54
 */
import router from '../router';
import { setToken } from '@/utils/storage';
export function toLogin() {
  window.parent.postMessage('logout');
  if (process.env.NODE_ENV === 'development') {
    setToken('');
    router.push('/');
  } else {
    console.error('您没有登录或操作超时,请重新登录');
  }
}
